#include "ads1271.h"

void ADS1271::begin()
{

    cfg.dev_num  = cs->id;
    cfg.bit_order = Spi::MSB;
    cfg.mode     = Spi::MODE0;
    cfg.prescaler = Spi::DIV2;
    
    spi->begin(&cfg);


}
int32_t ADS1271::read()
{
    uint32_t temp = 0;
    temp |= spi->read() << 16;
    temp |= spi->read() << 8;
    temp |= spi->read();
    return temp;
}
void ADS1271::process()
{

}

